<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en"> <![endif]-->
<!--[if IE 7]>    <html class="no-js ie7 oldie" lang="en"> <![endif]-->
<!--[if IE 8]>    <html class="no-js ie8 oldie" lang="en"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"><!--<![endif]-->
<head>
<base href="<?=current_url()?>">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <!-- Bootstrap -->
    <link href="<?php echo base_url()?>public/css/bootstrap.min.css" rel="stylesheet" media="screen">
    <link href="<?php echo base_url()?>public/css/style.css" rel="stylesheet" type="text/css">
    <link href="<?php echo base_url()?>public/prettyPhoto/css/prettyPhoto.css" rel="stylesheet" type="text/css">
    <link href="<?php echo base_url()?>public/css/font-awesome.css" rel="stylesheet" media="screen">
    <script src="http://code.jquery.com/jquery.js"></script>
    <script src="<?php echo base_url()?>public/prettyPhoto/js/jquery.prettyPhoto.js"></script>
    <script type="text/javascript" src="<?php echo base_url()?>public/js/leanModal/jquery.leanModal.min.js"></script>
    <script type="text/javascript">
        var cur_router = '<?php echo $this->rout?>';
        var baseUrlJs = '<?php echo base_url()?>';
        $(document).ready(function(){
             $("a[rel*=leanModal]").leanModal({closeButton: ".modal_close"});
        });
    </script>
</head>
<body>
  	<div class="container">
    <div class="row header_person">
        <div class="col-lg-4 col-lg-offset-2" style="margin-top:70px">
            <a href="#upload-photo" rel="leanModal" class="btn btn-primary">Upload photo</a>
        </div>
    </div>
  
</div>


<!--Popup upload photo for person -->
    <script src="<?php echo base_url()?>public/upload_lib/jquery.uploadify.min.js" type="text/javascript"></script>
    <link rel="stylesheet" type="text/css" href="<?php echo base_url()?>public/upload_lib/uploadify.css">
    <div style="display:none; height:400px" id="upload-photo" class="box-lean-modal">
          <div id="signup-ct">
            <div class="signup-header">
              <h2>Plase select photo</h2>
              <a class="modal_close" href="#"><i class="icon-remove"></i></a>
            </div>
          </div>
        <form style="margin-left:20px" enctype="multipart/form-data">

          <div id="notify"></div>
          <div id="queue"></div>
          <input id="file_upload" name="file_upload" type="file" multiple="true">
        </form>
     
    </div>
    <!--End popup-->
    <script type="text/javascript">
    <?php 
        $timestamp = time();
        //$session_name = $this->session->get_js_session(TRUE);
        //$session_data = $this->session->get_js_session();
    ?>
    $(document).ready(function() {
          $('#file_upload').uploadify({
            'formData'      : {
                'personName' : '8',
                'personId': '8',
 
            },
            'swf'      : '<?php echo base_url()?>public/upload_lib/uploadify.swf',
            'uploader' : '<?php echo base_url()?>test',
            'debug'    : false,
            'fileObjName' : 'userfile',
            'fileSizeLimit':'2048KB',
            'cancelImg': '<?php echo base_url()?>public/upload_lib/uploadify-cancel.png',
            'removeCompleted':false,
            
            'onUploadSuccess' : function(file, data, response) {
                alert('adasdsa');
            },
            'onComplete' : function(event, ID, fileObj, response, data) {
                //$("#notify").html(response);
                //alert(response);
             }
          });
    });
  </script>